home *** CD-ROM | disk | FTP | other *** search
/ Games of Daze / Infomagic - Games of Daze (Summer 1995) (Disc 1 of 2).iso / x2ftp / msdos / docs / gccfaq10 / video.c < prev   
Encoding:
C/C++ Source or Header  |  1995-02-15  |  354 b   |  28 lines

  1. #include <go32.h>
  2.    
  3. static int dos_seg, length;
  4. static char *string;
  5.  
  6. main()
  7. {
  8.  dos_seg = _go32_conventional_mem_selector();
  9.  string  = "H.e.l.l.o.";
  10.  length  = 10;
  11.  
  12.  asm ("
  13.   pushw %es
  14.   
  15.   movw  _dos_seg, %es
  16.   
  17.   movl  _string, %esi
  18.   movl  $0xb8000, %edi
  19.    
  20.   movw  _length, %cx
  21.   
  22.   rep ; movsb 
  23.   
  24.   popw  %es
  25.  ");
  26. }
  27.  
  28.